﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Microsoft.VisualStudio.TestTools.UnitTesting;
using Randata.Test.Model;

namespace Randata.Test
{
    [TestClass]
    public class InnerCustomObjectsTest
    {

        [TestMethod]
        public void Should_work_with_the_inner_objects()
        {
            Parent p = DataProvider.Any<Parent>();

            Assert.IsNotNull(p.Children, "The inner objects should be createds.");

            Assert.AreNotEqual(0, p.Children.Count, "The inner objects should be createds.");

            Assert.IsFalse(String.IsNullOrEmpty(p.Children.First().Name), "The inner object should be filled.");
        }

    }
}
